<?php

/**
 * 竞拍模块
 *
 * Created by PhpStorm.
 * User: evan
 * Date: 2016/12/13
 * Time: 上午11:28
 */
class Auction extends MY_M_Controller
{
    /**
     * 竞拍详情页面
     */
    public function detail()
    {
    	$aid = (int)$this->input->get_post('aid');


    	if(!$aid)
    	{
                //todolist 跳转到公共提示页面，不存在该直播
            echo "<script> alert('直播ID不能为空');parent.location.href='detail?aid=2083'; </script>";
        }



    	$this->load->service('auction/service_auction_detail');
    	$data = $this->service_auction_detail->index($aid, 1);


        //公开和私聊调用不同的view
        $showview=$data['data']['auction']['is_public']?'public_detail':'private_detail';

    	$this->load->view('m/auction/'.$showview, $data['data']);



    }
}